public class StudentGradeManager{
    public void recordGrade(String student)
    }
    public int queryGrade(String student)
        return -1;
    }
}public static void statsScore() {
    System.out.println("\n=== 统计课程成绩 ===");
    System.out.print("请输入课程名称: ");
    String course = scanner.nextLine();
    
    List<Double> scores = new ArrayList<>();
    for (Student s : students) {
        if (s.course.equals(course)) {
            scores.add(s.score);
        }
    }
    
    if (scores.isEmpty()) {
        System.out.println("该课程暂无成绩记录!");
        return;
    }
    
    double sum = 0;
    double max = scores.get(0);
    double min = scores.get(0);
    
    for (double score : scores) {
        sum += score;
        max = Math.max(max, score);
        min = Math.min(min, score);
    }
    
    double avg = sum / scores.size();
    
    System.out.printf("课程: %s\n", course);
    System.out.printf("平均分: %.2f\n", avg);
    System.out.printf("最高分: %.1f\n", max);
    System.out.printf("最低分: %.1f\n", min);
}

// 在showMenu()方法中添加菜单选项
case "3":
    statsScore();
    break;
    